#include <bits/stdc++.h>

using namespace std;
using ll = long long;
const int MAXN = 1e6 + 10;
const int MOD = 998244353;

int main() {
#ifdef LOCAL
    freopen("in.txt", "r", stdin);
    freopen("out.txt", "w", stdout);
#endif
    int x, y;
    map<int, int> m1, m2;
    for (int i = 1; i <= 3; i++) {
        cin >> x >> y;
        m1[x]++, m2[y]++;
    }

    for (auto [k, v] : m1) if(v == 1) x = k;
    for (auto [k, v] : m2) if(v == 1) y = k;
    cout << x << ' ' << y << endl;
    return 0;
}